{% extends 'base.html' %}

{% block con %}
    <div class="container">
        <div class="row">
            <!-- 左侧背景 -->
            <div class="col-md-8 body-img">
            </div>
            <!-- 右侧登录框 -->
            <div class="col-md-4 body-login">
                <h3 class="iconfont">测试账号 (&#xe62a;:&nbsp;test&nbsp;&nbsp;&#xe744;:&nbsp;123)</h3>
                <form class="form-horizontal" action="" method="post">
                    {% csrf_token %}
                    <div class="form-group">
                        <label for="id_usr" class="col-md-2 control-label iconfont">&#xe62a;</label>
                        <div class="col-md-10">
                            {{ form.usr }}
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="id_pwd" class="col-md-2 control-label iconfont">&#xe744;</label>
                        <div class="col-md-10" style="position: relative">
                            {{ form.pwd }}
                            <!-- 认证错误提示区域 -->
                            <span class="text-danger pull-right small" id="login_auth"
                                  style="position: absolute;right: 20px;top: 35px"></span>
                        </div>
                    </div>
                    <div class="form-group" style="padding-top: 10px">
                        <div class="col-md-offset-2 col-md-10">
                            <!-- 登录：ajax -->
                            <p class="btn btn-info btn-block" id="submit">登录</p>
                            <br>
                            <!-- 注册 -->
                            <div class="text-center small">
                                <span class="text-muted ">还没有账号 </span>
                                <a href="/app_auth/reg/">立即注册！</a>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
    <script>
        $.ajax({
            type: "POST",
            url: "https://www.helloxjn.com/log/",
            data: {
                'web': 'book',
            },
        });
    </script>
{% endblock %}